import { createApp } from "vue";
import ArcoVue from "@arco-design/web-vue";
import "@arco-design/web-vue/dist/arco.css";
import "./style.css";
import "./api/interceptor";
import App from "./App.vue";
import router from "./router";
const config: any = [];
const app = createApp(App);
const modules = import.meta.glob("./components/*.vue", { eager: true });
for (const key in modules) {
  const component: any = modules[key];
  let name = component.default.__name;
  let iconName = name.split("electrical_symbols_")[1]
  app.component(name, component.default);
  config.push({id:name,title:iconName,type:"custom-svg",thumbnail:`/electrical_symbols_library/${iconName}.svg`,props:{strokeColor:{type:"color",val:"#FF0000",title:"颜色",},propType:{type:"select",val:1,title:"变量类型",options:[{value:1,label:"模拟量",},{value:"2",label:"状态量",},],},state:{type:"select",val:1,title:"开关",options:[{value:0,label:"开",},{value:1,label:"关",},],},text:{type:"input",val:1,title:"内容",},},});
}
// leftAsideStore.registerConfig('电气符号', config);
app.use(ArcoVue);
app.use(router);
app.mount("#app");
